<?php
namespace app\api;
use think\Cache;
use think\Model;
use think\Request;

class BaseModel extends Model
{
    public $request;
    public $requestData;
    protected $user;
    public function __construct($data = [])
    {
        parent::__construct($data);
        $this->request = Request::instance();
        $this->requestData = empty($data)?$this->request->param(''):$data;
        if ($this->request->__get('user')){
            $this->user = $this->request->__get('user');
        }
    }


}